import Vue from "vue";
import VueRouter from "vue-router";
Vue.use(VueRouter);

const routes = [
	{
		path: "/ads",
		name: "ads",
		component: () => import("@/views/ads/ads.vue")
	},
	{
		path: "/ads/form",
		name: "ads-form",
		component: () => import("@/views/ads/form.vue")
	},
	{
		path: "/ads2",
		name: "ads2",
		component: () => import("@/views/ads2/ads.vue")
	},
	{
		path: "/ads2/form",
		name: "ads2-form",
		component: () => import("@/views/ads2/form.vue")
	},
	{
		path: "/college",
		name: "college",
		component: () => import("@/views/college/college.vue")
	},
	{
		path: "/pay-result",
		name: "pay-result",
		component: () => import("@/views/pay/result_old.vue")
	},
	{
		path: "/pay/success",
		name: "pay-success",
		component: () => import("@/views/pay/success.vue")
	},
	{
		path: "/pay/success1",
		name: "pay-success1",
		component: () => import("@/views/pay/success1.vue")
	},
	{
		path: "/test",
		component: () => import("@/views/test.vue")
	},
	{
		path: "/redirect/:path(.*)",
		component: () => import("@/views/redirect.vue")
	},
	{
		path: "/ad",
		name: "ad",
		component: () => import("@/views/ad/index.vue")
	},
	{
		path: "/ad/form",
		name: "ad-form",
		component: () => import("@/views/ad/form.vue")
	},
	{
		path: "/ads3/form",
		name: "ads3-form",
		component: () => import("@/views/ad/form3.vue")
	},
	{
		path: "/ads4/form",
		name: "ads4-form",
		component: () => import("@/views/ad/form4.vue")
	},
	{
		path: "/browser",
		name: "browser",
		component: () => import("@/views/browser.vue")
	},
	{
		path: "/browser",
		name: "browser",
		component: () => import("@/views/browser.vue")
	},
	{
		path: "/order/query",
		name: "order-query",
		component: () => import("@/views/order/query.vue")
	},
	{
		path: "/order/detail",
		name: "order-detail",
		component: () => import("@/views/order/detail.vue")
	},
	{
		path: "/order/service",
		name: "order-service",
		component: () => import("@/views/order/service.vue")
	},
	{
		path: "/order/complaint",
		name: "order-complaint",
		component: () => import("@/views/order/complaint.vue")
	},

	{
		path: "*",
		redirect: "/ad"
	}
];

const router = new VueRouter({
	mode: "history",
	base: process.env.BASE_URL,
	routes
});

export default router;
